// The Vue build version to load with the `import` command
// (runtime-only or standalone) has been set in webpack.base.conf with an alias.
import Vue from 'vue'
import App from './App'
import router from './router'
import axios from 'axios'

import store from './store/index.js'

import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css'
import VCharts from 'v-charts'
import vuescroll from 'vue-scroll'

import VueVideoPlayer from 'vue-video-player'
import 'video.js/dist/video-js.css' // 引入样式
import 'vue-video-player/src/custom-theme.css' // 引入样式
import 'videojs-flash'
// import fun from 'src/ezuikit/ezuikit.js';
// Vue.prototype.$ezuikit=fun;  //其中$xx为新命的名。
Vue.use(VueVideoPlayer)
Vue.use(vuescroll)
Vue.config.productionTip = false

const baseUrl = process.env.API_ROOT
// 把baseUrl挂载到Vue原型上，方便组件内部使用
Vue.prototype.baseUrl = baseUrl;

const webUrl = process.env.apiRoot
// 把baseUrl挂载到Vue原型上，方便组件内部使用
Vue.prototype.webUrl = webUrl;

const host = process.env.host
// 把baseUrl挂载到Vue原型上，方便组件内部使用
Vue.prototype.host = host;

const url = process.env.url
// 把baseUrl挂载到Vue原型上，方便组件内部使用
Vue.prototype.url = url;

Vue.prototype.$ajax = axios

Vue.use(ElementUI)
Vue.use(VCharts)

/* eslint-disable no-new */
new Vue({
  el: '#app',
  router,
  store,
  components: { App },
  template: '<App/>'
})
